<?php
    include('checkAdminAccess.php');
    $iniVars = parse_ini_file('../../config.ini',TRUE);
    include('../classes/adodb5/adodb.inc.php');
    include('../function/db.func.php');
    
    $prideWorkTitle = $_POST['prideWorkTitle'];
    $prideWorkMsg = $_POST['prideWorkMsg'];
    $prideWorkSection = $_POST['prideWorkSection'];
    $prideWorkActive = $_POST['prideWorkActive'];
    $pwId = $_POST['pwId'];
    
    $sql = "UPDATE pride_work SET pw_msg='$prideWorkMsg' , pw_show_in='$prideWorkSection' , pw_active='$prideWorkActive' , pw_title='$prideWorkTitle' WHERE pw_id=$pwId";
    $result = $db->Execute($sql);
    
    if($result){
       echo 'success';
    }else{
        echo 'fail';
    }
?>